package com.woniuxy.store.client;

import com.woniuxy.store.client.param.couponParam.ModifyCouponTypeStateParams;
import com.woniuxy.store.client.param.couponTypeParam.AddCouponTypeParams;
import com.woniuxy.store.client.param.couponTypeParam.ModifyCouponTypeParams;
import com.woniuxy.store.client.param.couponTypeParam.QueryCouponTypeParams;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.web.bind.annotation.*;
import result.Result;

@FeignClient(contextId = "couponTypeClient",name = "store",path = "/store/marketing")
public interface CouponTypeClient {
    @PostMapping({"/addCouponType"})
    Result addCouponType(@RequestBody AddCouponTypeParams param);

    @DeleteMapping({"/deleteCouponType"})
    Result deleteCouponType(@RequestParam("couponTypeId") Integer couponTypeId);

    @PutMapping({"/modifyCouponType"})
    Result modifyCouponType(@RequestBody ModifyCouponTypeParams param);

    @PutMapping({"/modifyCouponTypeSuperposition"})
    Result modifyCouponTypeSuperposition(@RequestParam("superposition") Integer superposition, @RequestParam("couponTypeId") Integer couponTypeId);

    @PutMapping({"/modifyCouponTypeState"})
    Result modifyCouponTypeState(@RequestBody ModifyCouponTypeStateParams modifyCouponTypeStateParams);

    @GetMapping({"/queryCouponType"})
    Result queryCouponType(@SpringQueryMap QueryCouponTypeParams param);
}
